package com.uzai.common.enums;

/**
 * SOP独家功能菜单权限code
 * @Auther: liuqi
 * @Date: 2023/03/14 16:45
 * @Webhookription:
 */
public enum SopMenuCodeEnum {
    sopExclusiveWithdrawConfig("sopExclusiveWithdrawConfig","SOP独家功能-提现风控"),
    sopExclusiveOrder("sopExclusiveOrder","SOP独家功能-订单风控"),
    sopExclusiveAbnormal("sopExclusiveAbnormal","SOP独家功能-异常客户"),

    ;

    private String code;
    private String desc;

    SopMenuCodeEnum(String code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }


    public static SopMenuCodeEnum getByCode(String code) {
        if (code == null) {
            return null;
        }
        for (SopMenuCodeEnum demo: SopMenuCodeEnum.values()) {
            if (demo.getCode().equals(code)) {
                return demo;
            }
        }
        return null;
    }
}
